home *** CD-ROM | disk | FTP | other *** search
-
- // By using BAMS, it's very fast to mask off and wrap angles.
- #define SIN(x) ( SIN_TABLE[x] )
- #define COS(x) ( SIN_TABLE[x+SIN_TO_COS_ADDER] )
- #define SAFE_SIN(x) ( SIN_TABLE[x&ANGLE_MASK] )
- #define SAFE_COS(x) ( SIN_TABLE[ (x+SIN_TO_COS_ADDER) & ANGLE_MASK ] )
- extern Fixed SIN_TABLE[ANGLE_RES];
-
- // ArcCosine table, used for lighting calculations.
- extern Fixed ACOS_TABLE[ANGLE_RES];
-
- // An ArcTangent lookup table. Goes from atan(0) to atan(1).
- // Values are in fixed-point. See BSP_GEN's GetAngle for an
- // example of using this table.
- extern Angle ATAN_TABLE[ANGLE_RES];
-
- // Tells which video mode we're in:
- // 0 = 320x200
- // 1 = 320x240
- // 2 = 360x360
- // 3 = 360x480
- // 4 = 400x600
- extern WORD videoMode;
-
- // These are what the routines in DRAW consider the screen boundaries.
- extern DWORD s_DrawWidth, s_DrawHeight;
- extern DWORD s_MinX, s_MaxX, s_MinY, s_MaxY;
-
- // The screen width and height.
- extern DWORD s_Width, s_Height;
-
- // The width (what you multiply Y coordinates by) in paged VGA.
- // In linear VGA, this is the same as s_Width;
- extern DWORD s_PagedWidth;
-
- // A loopup table the size of s_Width to get the position in the screen memory
- // for a certain x coordinate.
- extern DWORD *s_PageLookup;
-
- // The size of the screen in bytes.
- extern DWORD s_SizeBytes;
-
- // A pointer to the offscreen buffer.
- extern BYTE *pScreenMem;
-
- // The pointer to the actual VGA buffer.
- extern BYTE *pVgaMem;
-
- // Number of colors in the palette maps.
- extern WORD nPaletteColors;
-
- // Number of palette maps.
- extern WORD nPaletteMaps;
-
- // The palette lookup table.
- extern BYTE **pPaletteMaps;
-
- // The transparancy lookup.
- extern BYTE **pTranspal;
-
- // What palette map to use on the parallaxing sky.
- extern WORD parallaxMap;
-
- // The palette for making everything black and white.
- extern BYTE blackWhitePal[256];
-
- // Tells if everything will be black and white.
- extern BOOL bBlackAndWhite;
-
- // The distance away from you that things fade out at.
- extern WORD zFadeOut;
-
- // Just stores the current level.
- extern Level curLevel;
-
- // The player..
- extern Player player;
-
- // Incremented every clock tick.
- extern DWORD timeCount;
-
-
- // Displays points at all the vertices.
- extern BOOL bDisplayProjectionPoints;
-